# Contributor: Bart Ribbers <bribbers@disroot.org>
# Maintainer: Bart Ribbers <bribbers@disroot.org>
pkgname=libinputsynth
pkgver=0.16.0
pkgrel=0
pkgdesc="Synthesize keyboard and mouse input on X11 and Wayland with various backends"
url="https://gitlab.freedesktop.org/xrdesktop/xrdesktop"
arch="all"
license="MIT"
depends_dev="
	gobject-introspection-dev
	xdotool-dev
	"
makedepends="$depends_dev
	gtk-doc
	meson
	"
source="https://gitlab.freedesktop.org/xrdesktop/libinputsynth/-/archive/$pkgver/libinputsynth-$pkgver.tar.gz"
subpackages="$pkgname-dev $pkgname-doc"

build() {
	abuild-meson \
		-Dapi_doc=true \
		. output
	meson compile -C output
}

check() {
	meson test --no-rebuild --print-errorlogs -C output --no-suite post-install
}

package() {
	DESTDIR="$pkgdir" meson install --no-rebuild -C output
}

sha512sums="
06568d8217823d479bee301954516b64968c188645ea073dc30b5152a13e922bca43474e66c55edd02ef0c7013a7cad5e2e16e4169d1fa0faacf54b0467ec764  libinputsynth-0.16.0.tar.gz
"
